Fast serial interface used for controller to robot communications

ABSTRACT

A fast serial interface including a three-wire network connection between a bus controller and one or more bus devices is disclosed. The bus controller processes and issues data packets across the three-wire network that include a command code, a bus device selection code, and a bus device register selection code. If the command code corresponds to write code, then the selected bus device stores the data contained within the packet in the selected register. If the command code corresponds to a read command, the selected bus device retrieves the data stored in the selected register, forms a read data packet and transfers the read data packet to the bus controller.

CROSS REFERENCE TO RELATED APPLICATIONS

N/A

STATEMENT REGARDING FEDERALLY SPONSORED RESEARCH OR DEVELOPMENT

N/A

BACKGROUND OF THE INVENTION

Control of industrial robots requires high speed data lines fortransmitting commands to the various robot systems from the robotcontroller and for receiving status data of the various robot systems bythe robot controller. Typically, current robot controllers utilize oneor more high speed parallel data busses to communicate to and from therobot.

High speed parallel data buses require a single conductor for each databit that is to be transferred to or from the various robot systems andthe robot controller. For a high density and high speed transmissionsystem there will be numerous conductors running between the robotcontroller and the various robot systems. Also, in addition to the datacarrying conductors, a number of conductors will be required to carryoverhead data such as read and write commands and system selectcommands. As the chassis and the physical size of various systemscontinues to decrease, space becomes a more valuable commodity. The useof a parallel data transmission system requires an increased pin countas more systems are linked together and/or larger data words are used.This increased pin count will result in larger interface interferencebetween the pins and conductors that will need to be in close proximityto one another will increase as well. This increase in interference canresult in increased complexity in terms of circuits and systems andincrease the cost of these systems as well. In addition, as thephysically available space decreases, the amount of space taken up byparallel conductor runs inside the chassis can reduce the internal airflow resulting in increased complexity and cost to ensure that propercooling occurs. Also, purchasing, installing, maintaining, and troubleshooting multiple conductor parallel data communication can be a costlyinvestment for any system. In addition, the time required to troubleshoot a malfunctioning parallel communication system increases with thenumber of conductors carrying data.

Therefore what is needed in the art is a simple data interface systemthat is easy to route within a chassis, robust in its ability to carryhigh speed data, and able to perform data error checking.

BRIEF SUMMARY OF THE INVENTION

A fast serial interface including a three-wire network connectionbetween a bus controller and one or more bus devices is disclosed. Thebus controller processes and issues data packets across the three-wirenetwork that include a command code, a bus device selection code, and abus device register selection code. If the command code corresponds towrite code, then the selected bus device stores the data containedwithin the packet in the selected register. If the command codecorresponds to a read command, the selected bus device retrieves thedata stored in the selected register, forms a read data packet andtransfers the read data packet to the bus controller.

Additional aspects, features and advantages of the present invention arealso described in the following Detailed Description.

BRIEF DESCRIPTION OF THE SEVERAL VIEWS OF THE DRAWING

The invention will be more fully understood by reference to thefollowing Detailed Description of the Invention in conjunction with thedrawings of which:

FIG. 1 is a block diagram of a serial interface consistent with thepresent invention;

FIGS. 2A and 2B are schematic representations of the two interpretationsof the control and status registers of FIG. 1;

FIG. 3 is a schematic representations of the bus controller statusregister of FIG. 1;

FIG. 4 is a schematic representations of the bus controller dataregister of FIG. 1;

FIG. 5 is a schematic representations of the bus device status registerof FIG. 1;

FIGS. 6A and 6B are schematic representations of the bus device statusregister and configuration register of FIG. 1;

FIGS. 7A and 7B are schematic representations of the bus device dataoutput register of FIG. 1;

FIG. 8 is a schematic representations of the bus device data inputregister of FIG. 1;

FIG. 9 is a schematic representations of the bus device interrupt maskregister of FIG. 1;

FIG. 10 is a schematic representations of the bus device pointerregister of FIG. 1;

FIG. 11 is a schematic representations of the bus device pointer dataregister of FIG. 1.

DETAILED DESCRIPTION OF THE INVENTION

FIG. 1 depicts a three-wire serial network 100 suitable for use with thepresently described serial communications system between a buscontroller and a bus device. The network 100 includes a bus controller102 coupled to a bus device 104 via a three wire network connection 112.The three-wire network connection 112 includes a transmit wire 111, fortransferring data packets from the bus controller to a bus device, areturn wire 113, for transmitting data packets from a bus device to thebus controller, and a clock line 115 for providing a clock signal fromthe bus controller to the bus device.

There can be a plurality of bus devices (not shown) that may beconnected in parallel (not shown) to the three-wire network connection112, or one or more bus devices may be connected in a cascade fashion(not shown), wherein the three-wire network connection 112 is passedthrough each bus device to a subsequent bus device. Alternatively, theremay be two or more network devices connected to the three-wire networkconnection in parallel (not shown) wherein one or more of the networkdevices may have other devices connected in a cascade manner to them(not shown).

The bus controller 102 and the bus device 104 both include a processor106/122, respectively, coupled to a memory 109/120, respectively, adata-transmit-receive-network-interface 110/124, respectively, and aplurality of data registers 108/126, respectively. The datatransmit-receive network interface 110 provides the necessary signalconditioning, the appropriate signals level, the necessary filtering andsignal detection for the data transmitted and received from the network.The memory 111 provides a plurality of data storage locations to storevarious software programs and the data associated therewith. Theplurality of control and data registers 104 and 126 respectively,provide device control and status data, network overhead data, andsystem data for the bus controller 102 and the bus device 104. Asdescribed in more detail below, the processor 106/122 and thedata-transmit-receive-network-interface 110/120 utilize the datacontained in the various data registers 108/126 to form a data packetfor transmission over the three-wire network connection 112.

A data packet is transmitted between the various network components, andthe interpretation of the various bytes comprising the packet changes ifthe packet is providing a “data out” function, i.e., when data is beingtransmitted from the bus controller to one or more bus devices, or a“data in” function, i.e., when data is being transmitted from a busdevice to the bus controller. The table below illustrates the datapacket used within the current serial communication system:

TABLE 1 Bits Data Out Data In 0, 1, 2 Synchronization Bits, in Tri statecondition a 101 pattern 3, 4 Command being asserted to Status bit 7 and6, Status the bus: 01 read data for each device, and the from busdevice; 10 write status for that bit time data to a bus device, 11corresponding to the reset, 00 null devices' physical address 5, 6, 7Physical bus device Status bits Select, up to eight devices may exist 8,9, 10 Register select within Status bits the selected physical busdevice 11 Asserted as zero, used Asserted by downstream for wait statedevice as a request to open a gateway to the bus for bits 12-19 (Readdata) and bits 20-22 parity or collision error 12-19 Write data bits 7-0Read data bits 7-0 20 Even parity assertion by Calculated even paritybus controller for bits asserted by the selected 0-19 bus device fordata in bits 12-19, this is compared to the incoming parity error andreport a difference in bit 21 21 Parity calculation error Parity errorasserted by asserted by the bus the bus device controller 22 Buscollision at the Collision detected by the parallel connection as busdevice in the cascaded detected by the bus configuration controller.Prior command is ignored. 23-25 Null, no clock Null, no clock

Accordingly, the bus controller 104 is able to write or read datato/from any of the plurality of registers of the bus devices 102 byappropriately setting the appropriate bits in the packet. In this way,the bus controller can receive stored data by reading the appropriateregister within a selected bus device and control the bus device bywriting data to the appropriate control register within the selected busdevice. Also, each of the registers has a different interpretationdepending on whether the function is a data out (write data) function ora data in (read data) function.

In the embodiment depicted in FIG. 1, the network controller includesthree control and data registers 108 corresponding to a controller andstatus register 130, a network device status register 132, and a dataport register 134.

The control and status register 130 contains data relating to theselection of a particular bus device and a particular register thereof.The interpretation of the control and status register 130 depends on thelast command executed. If the last command was a reset command, then theinterpretation of the controller and status register 130A is provided inFIG. 2A. If the last command was not a reset command then theinterpretation of the controller and status register 130B is provided inFIG. 2B.

As depicted in FIG. 2A the last command was a reset command and theinterpretation of the of the first 6 bits, bits 0-5, select the registerand the bus device in both the write data and read data functions. Inparticular, bits 0-2 select the register, and bits 3-5 select the busdevice. Bits 6 and 7 store the appropriate command bits as discussed inTable 1 above. As such, If the function to be performed is a writefunction, then bits 6 and 7 contain the reset command LSB and MSB, i.e.,1, 1 respectively. If the command is a read function then bits 6 and 7contain the command bits LSB and MSB respectively.

If the last command was not a reset command then as depicted in FIG. 2B,the first 6 bits, bits 0-5, select the register and the bus device asdescribed above in the data out (write function). In particular, bits0-2 select the register, and bits 3-5 select the bus device. If it is adata in (read) function that is being performed, bits 0-2 provide athree bit error code, and bits 3-5 provide the address of the deviceselected. In particular, the error codes are given by:

TABLE 2 Error Code Meaning 000 No errors on bus transaction 001 Writeparity error 010 Read parity error 100 Command collision 101 Writeparity error retry failure (3 retries and failed) 110 Read parity errorretry failure (3 retries and failed) 111 Bus Collision

In addition, if a write function is being performed bits 6 and 7 containthe command least significant bit and most significant bit respectively.If a read function is to be performed, bit 6 contains a bus deviceinterrupt request when set to 1 and bit 7 contains a command completeflag when set to 1.

As depicted in FIG. 3 the bus device status register 132 contains 7bits. There are no defined functions if the function to be performed isa write function for bits 0-7, however, if a read function is beingperformed then each bit contains a device status bit of a correspondingpredetermined bus device. As depicted in FIG. 3, there can be up to 8bus devices attached to the bus controller.

FIG. 4 depicts the bus controller data port register 134. If a writefunction is to be performed the data to be written to the particular busdevice and register are contained in bits 0-7. If a read function isbeing performed the data from a particular device register is placed inbits 0-7 of this register.

As discussed above with respect to the bus controller registers 108, thevarious bits in each of the bus device registers has a differentinterpretation if a write or a read function is being performed. Asdepicted in FIG. 1, the bus device 104 includes 8 separate dataregisters. In particular as depicted in FIG. 5, register 140 is a busdevice control and status register. If a write function is beingperformed, bits 0 and 1 are reserved and set to 0. Bit 2 is a bus devicecontrol and status register mux select bit which determines the functionof the next register, 142, which may be the bus control and statusregister expansion or the bus device configuration code. If bit 2 is setto 1 then register 142 will be the bus control status registerexpansion. Bit 3 of register 140 enables interrupts for both a write anda read function, and bit 4 invokes a self test for a write function andprovides a self test complete flag for a read function. Bits 5 and 6provide initialization of a home device for a write function and aninitialization complete flag for a read function. Bit 7 is a reset bitfor a write function and an internal error flag for a read function.

As discussed above, if bit 2 of the write function of register 140 isset to 1 then register 142 is interpreted as depicted in FIG. 6A asregister 142A. In particular, bits 0-2 force a calculated error which isa cascade collision error for bit 0, a parity error for the next readcycle for bit 1 and a write parity error for this cycle for bit 2 for awrite function and provide an error indication for a cascade buscollision error, bit 0, a self-test error, bit 1, and a calculated buswrite error, bit 1, for a read function. Bits 3-7 are not defined for awrite function. However for a read function, bit 3 indicates an internalor CRC error has occurred, bit 4 indicates a bus synchronization errorhas occurred, bit 5 and 6 indicate that a server following error hasoccurred and bit 7 indicates an interrupt overrun error.

If the bit 2 in the register 140 is set to 0 then the register 142 isinterpreted as depicted in FIG. 6B as register 142B. In particular, fora write function there is no defined interpretation for the bits 0-7. Ifa read function is being performed bits 0-1 indicate the board revisionnumber, bits 2-14 indicate the Xilink configuration data, bits 5-7indicate the board configuration data.

Registers 144 and 146 provide the bus device output register. Inparticular, register 144 and 146 depicted in FIGS. 7A and 7Brespectively provide up to 16 bits of data to be written across thethree-wire network. In the case of a read function being performed, thebits in the registers 144 and 146 provide the function of “read what youwrote”, in which the bits of data that were transferred to the buscontroller are stored in the corresponding register. Register 148 isdepicted in FIG. 8 and is the bus device input register. If a writefunction is being performed there is no defined interpretation of thebits in register 148. If a read function is being performed bits 0-7provide the input data written to the register and the bus device fromthe bus controller.

Register 150 is a bus device interrupt mask enable register. Inparticular, register 150 during a write function provides interruptenable bits 0-7. If a read function is being performed there is nodefined interpretation for the bits contained within this register.

Register 152, as depicted in FIG. 10, is the bus device pointer registerthat points to one of a plurality of predetermined memory locations 151contained in the memory space of the processor 122. In particular, if awrite function is being performed by the register, bits 0-6 provide theactual pointer location of 0-128 pointer locations. Bit 7 is a pointerfreeze flag indicating that no increment is to be performed on thepointer locations. If a read function is being performed, bits 0-6contain the current pointer location. Bit 7 is a “read what you wrote”for bit 7 in the write function.

Register 154 is the bus device data read write register for pointerdata. If a write function is being performed then bits 0-7 contain thewrite data value to be written to a particular pointer location, and ifa read function is being performed the data bits 0-7 contain data readfrom a particular pointer location.

The pointer locations described with respect to FIG. 10 are typicallycontained within the memory space of the particular bus device 104. Inone embodiment, the pointer locations 0-63 are reserved for externaldevices and the pointer locations 64-127 are reserved for internalregisters such 4 channel A-D inverters. FIG. 12 depicts a particularembodiment of data registers receiving data from various externaldevices (not shown) but is written and read from the various pointerlocations. In particular, as depicted in FIG. 12 for a pointer locationof 40 (hex) through pointer location 4B (hex) various A/D channels (notshown). In this embodiment, pointer locations 00 (hex) through 08 (hex)can be used to store data from 3 16 bit encoder latches (not shown).

As depicted in FIG. 1 the bus device 104 can include a plurality ofFlash memory 156. In one embodiment, the Flash memory support isincluded in four of the 1218 pointer locations. In one embodiment, thepointer location 20 (hex) includes the Flash memory write enable andsector select data, the pointer location 21 (hex) includes upper halfpointer register, the pointer location 22 (hex) includes the lower half10 pointer register, and pointer location 23 (hex) includes the Flashmemory data register for reading or writing from/to the Flash memory156.

In one embodiment the bus controller is a robot controller and one ormore bus devices correspond to one or more robotic applications. Thevarious robotic applications can include data collected from varioussensors or provide data such as threshold data to various sensors. Inone embodiment, the pointer locations 00 (hex) to 08 (hex) can receivethe bits from one or more encoder latches (not shown) configured andarranged to encode the various aspects of the robotic applications.Pointer location 10 (hex) can contain data configured and arranged toselect a particular latch encoder. In this embodiment, there may be upto 3 latch encoders having up to 24 bits each. The pointer locations 40(hex) through 44 (hex) can receive data from a variety of sensors, suchas vacuum sensor 1 and 2, pointer locations 40 (hex) and 41 (hex)respectively, a temperature sensor, pointer location 42 (hex), ahumidity sensor, pointer location 43 (hex), and a threshold value for avacuum sensor, pointer location 44 (hex). The pointer locations 44 (hex)through 47 (hex) can write the upper and lower threshold data from thevacuum sensor 1 and 2, pointer locations 44 (hex) and 45 (hex)respectively, and the upper and lower threshold values for thetemperature sensor, pointer location 46 (hex). Pointer location 47 (hex)can be used to write upper and lower threshold data for the humiditysensor. Pointer locations 48 (hex) through 4B (hex) can receive A/D datato be read by the bus device from a house vacuum sense, pointer location48 (hex) and up to three sensors to be determined, pointer locations 49,4A, and 4B (hex).

When transferring data between the bus controller 102 and the bus device104, the bus controller transmits a single data packet onto the transmitwire. The transmitted data packet includes a command code, the busdevice selection code, and the register selection code as describedabove. If the command code is write command, the selected bus devicereceives the data packet and transfers the data contained therein intothe selected register. If the command code is a read command, theselected bus device retrieves the data from the selected data register,forms a data in packet using the data from the selected data registerand transmits the data packet to the bus controller 102.

Those of ordinary skill in the art should further appreciate thatvariations to and modification of the above-described methods andapparatus for fast serial communication system may be made withoutdeparting from the inventive concepts disclosed herein. Accordingly, theinvention should be viewed as limited solely by the scope and spirit ofthe appended claims.

What is claimed is:
 1. An apparatus for providing serial datacommunication between a first robot bus device and a second robot busdevice, the apparatus comprising: a first robot bus device acting as abus controller; a second robot bus device; a three wire networkconnection including a first data line to transmit data from the firstrobot bus device to the second robot bus device and a second data lineto transmit data from the second robot bus device to the first robot busdevice, and a clock line having a clock signal thereon for providing aclock signal from the first robot bus device to the second robot busdevice; the first robot bus device coupled to the second robot busdevice via the three wire network connection; and a multi-bit datapacket that is a data out packet including, a data synchronizationportion, a command portion, a receiver selection portion, a dataportion, a parity portion, and an error portion.
 2. The apparatus inclaim 1 wherein the data packet further includes: the datasynchronization includes 3 bits for packet synchronization; the commandportion includes 2 bit field command select; the receiver selectionportion includes 6 bits; the data portion includes 8 bits of data; theparity portion includes 1 bit of even parity for the 8 bits of data, 1bit for parity error detect for the 8 bits of data, and 1 bit of evenparity; and the error portion includes 1 bit for bus collision status.3. The apparatus of claim 2 further including a null portion.
 4. Theapparatus of claim 3 wherein the null portion includes 3 bits.
 5. Theapparatus of claim 2 wherein the 6 bit receiver selection portionincludes 3 bits to select the second robot bus device and 3 bits toselect a one of a plurality of registers therewithin.
 6. The apparatusof claim 1 wherein the first robot bus device further comprises: a firstrobot bus device control and status register that stores a plurality ofbus device selection data; and a first robot bus device data registerthat stores a plurality of data transferred to and from the second robotbus device.
 7. The apparatus of claim 1 wherein the second robot busdevice further comprises; a second device data register that stores aplurality of data to be transferred to and from the first robot busdevice.
 8. A method for transferring data between a first robot busdevice and a second robot bus device having a plurality of dataregisters, the first robot bus device including a control register forstoring second robot bus device selection data, second robot bus deviceregister selection data, and command data, and a data transfer registerfor storing data to be transferred to and from the selected bus device,the second robot bus device plurality of data registers including a datatransfer register for storing data to be transferred to and from thefirst robot bus device, the method comprising: providing second robotbus device selection data; storing said second robot bus deviceselection data in said control register; providing second robot busdevice register selection data; storing said second robot bus deviceregister selection data in said control register; providing data to betransferred; storing said data to be transferred in said first robot busdevice data register; and forming a data packet including a plurality ofpacket data including, a data synchronization portion, a commandportion, a receiver selection portion, a data portion, a parity portion,and an error portion.
 9. The method of claim 8 wherein the data packetincludes a data synchronization portion including 3 bits in apredetermined synchronization pattern for packet synchronization; thecommand portion including 2 bits as a command code read from the firstrobot bus device control register; the receiver selection portionincluding 6 bits; the data portion including 8 bits of data to betransferred read from the first robot bus device data transfer register;the parity portion 1 bit of even parity for the 8 bits of data, and 1bit for parity error detect for the 8 bits of data and the 1 bit of evenparity; and the error portion 1 bit for bus collision status; andtransferring the data packet from the first robot bus device to thesecond robot bus device over a serial link including a first datatransfer line and a clock line having a clock signal thereon.
 10. Themethod of claim 9 wherein the data packet further includes a null dataportion.
 11. The method of claim 10 wherein the null data portionincludes 3 bits.
 12. The method of claim 10 wherein the 6 bit includes abus robot device selection portion and a register selection portion. 13.The method of claim 12 wherein the bus robot device selection portionincludes 3 bits and the register selection portion includes 3 bits. 14.The method of claim 9 wherein the command code is a write command, themethod further including the steps of: receiving the data packet by thesecond robot bus device corresponding to the second robot bus deviceselection data; reading the 8 bits of data in the device packet; andstoring the 8 bits of data in the register corresponding to the secondrobot bus device register select data.
 15. The method of claim 9 whereinthe command code is a read command, the method further including thesteps of: receiving the data packet by the second robot bus devicecorresponding to the second robot bus device selection data; reading thedata stored in the register corresponding to the second robot bus deviceregister select data; forming a read 26 bit packet data including, 3bits for packet synchronization; 8 bits indicating status of each of thesecond robot devices; 8 bits of data; 1 bit of even parity for the 8bits of data 1 bit for parity error detect for the 8 bits of data and 1bit of even parity; 1 bit for bus collision status; and 3 bit as a nullfield; and transferring the read 26 bit data packet to the first robotbus device.